

public class Date {
    public int year;
    public int month;
    public int day;

    public Date(){
        this(2024,5,18);
    }

    public Date(int year,int month,int day ){
        this.day=day;
        this.year=year;
        this.month=month;
    }

    public void setDay(int year,int month,int day){
        this.year=year;
        this.month=month;
        this.day=day;
    }
    public void printDate(){
        System.out.println(this.year+"/"+this.month+"/"+this.day);
    }
    public static void main(String[] args) {
        Date d=new Date();
        d.setDay(2024,5,19);
        d.printDate();
    }
}
